This invention relates to a method and apparatus for sensing current position in a position control system for controlling the position of a single servomotor by means of a plurality of control devices. More particularly, the invention relates to a method and apparatus for sensing current position in a position control system so improved as to eliminate a positional error when switching among a plurality of control devices to drive and control a servomotor.
A system is available in which a movable machine element driven by a single servomotor is positionally controlled by placing the servomotor alternatively under the control of a plurality of control devices. By way of example, when machining a single workpiece by a machine tool operated under numerical control, portions of the workpiece that involve complex programming because of the sophisticated shape thereof are subjected to tracer control machining by a tracer control device, whereas the portions of the workpiece that are simple in shape are subjected to ordinary numerically controlled machining by a numerical control device. Such a technique makes it possible to machine the workpiece into the desired shape.
In the above-described position control system, the servomotor of the machine tool is positionally controlled by both the numerical control device and tracer control device to machine the workpiece as desired. Accordingly, during the period that the numerical control device is connected to the servomotor to drive the same, no connection exists between the servomotor and the tracer control device. Conversely, during the period that there is a connection between the tracer control device and the servomotor to drive the motor, the numerical control device is severed from the motor.
The numerical control device and tracer control device each incorporate a current position register to keep track of the current position of the movable machine element driven by the servomotor. Since control of the movable machine element of the machine tool is effected on the basis of the data stored in these registers, it is necessary for the amount of servomotor rotation to be sensed and for the current position registers to be updated based upon such rotation. This is true even for the position register incorporated in the control device not connected to the servomotor during such rotation. To this end, a so-called follow-up control method is available wherein the data stored in the error register of a position control circuit, provided in each of the control devices, is read in order to update the current position register. Because of an offset voltage which develops in the position control circuit, however, a problem arises wherein the servomotor is caused to drift each time it is switched over from one control device to the other, such drift being accompanied by an error which accumulates in the current position registers.